import { _decorator, Component, Node, Button, director } from 'cc';
import { GameManager } from '../GameManager';
const { ccclass, property } = _decorator;

@ccclass('UIResult')
export class UIResult extends Component {
    @property(Button)
    public BackBtn:Button
    start() {
        this.BackBtn.node.on(Button.EventType.CLICK, this.OnClickBtn, this);
    }
    
    OnClickBtn(btn:Button)
    {
        console.log("下一关！")
        GameManager.instance.NextLevel()
        this.node.destroy()
        // director.loadScene("start")
    }
}


